import { Component, OnInit, Input, Output, EventEmitter, HostBinding } from '@angular/core';

import { Suggestion } from './rxjs-suggestion.model';

@Component({
  selector: 'guide-rxjs-suggestion',
  templateUrl: './rxjs-suggestion.component.html',
  styleUrls: ['./rxjs-suggestion.component.css']
})
export class RxjsSuggestionComponent implements OnInit {
  @Input() suggestion: Suggestion;
  @HostBinding() class = 'row';
  @Output() deleted = new EventEmitter();
  constructor() { }

  ngOnInit() {
  }
  onDelete() {
    this.deleted.next(this.suggestion);
    return false;
  }
}
